pub fn odd_fibnacci_sum(threshold: u32) -> u32 {
    // TODO: 这里写逻辑
    // todo!()
    let mut index=1;
    let mut ans=0;
    let mut res=fibnacci(index);

    while res<threshold {
        if res%2==1 {
            ans+=res;
        }
        index+=1;
        res=fibnacci(index);
    }

    ans
}

pub fn fibnacci(n:u32) -> u32 {
    if n==1 || n==2 {
        return 1;
    }
    return fibnacci(n-1)+fibnacci(n-2);
}
